<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="css/4.详情页.css">
    <link rel="stylesheet" href="css/qingchu.css">
</head>

<body>
    <header></header>
    <nav>
        <div class="suoyin">
            <div class="suoyin_banner">
                <strong><a href="手机列表.html">手机数码</a></strong>
                <span style="color: #333;font-size: 12px;">
                    &nbsp;&nbsp;>&nbsp;&nbsp;
                    <a href="#" style="color: #333;">手机通讯</a>
                    &nbsp;&nbsp;>&nbsp;&nbsp;
                    <a href="#" style="color: #333;">智能手机</a>
                    &nbsp;&nbsp;>&nbsp;&nbsp;
                    <a href="#" style="color: #333;">乐视</a>
                    &nbsp;&nbsp;>&nbsp;&nbsp;
                </span>
                <span style="color: #aaa;font-size: 12px;">乐视手机s1</span>
            </div>
        </div>

    </nav>
    <div class="big_banner">
        <div class="big_banner_xiangqing">
            <div class="big_banner_xiangqing_left">
                <div id="small-box">

                    <div id="mask"></div>
                </div>
                <div id="bigg-box">

                </div>
                <div id="Imgs">
                    <img class="imgs1" id="img1" src="imgs/0.jpg" alt="">
                    <img class="imgs1" id="img2" src="imgs/1.jpg" alt="">
                    <img class="imgs1" id="img3" src="imgs/2.jpg" alt="">
                    <img class="imgs1" id="img4" src="imgs/3.jpg" alt="">
                    <img class="imgs1" id="img5" src="imgs/4.jpg" alt="">
                </div>
            </div>
            <div class="big_banner_xiangqing_right">
                <div class="big_banner_right_left" id="cent">
                    <div class="big_banner_center_top arr.goodsName">
                        <h1></h1>
                        <div> </div>
                    </div>
                    <div class="big_banner_center_cent">
                        <div class="shangchengjia">
                            <span style="font-size: 12px;color: #666;">商城价</span>
                            <i id="jiage" style="vertical-align:middle;color: #e4393c;font-size: 20px;">￥</i>
                        </div>
                        <div class="shichangjia">
                            <span>市场价</span>
                            <del class="del">￥</del>
                        </div>
                        <div class="leijipingjia">
                            <p style="color: #999;font-size: 12px;">累计评价</p>
                            <a id="pingjia" href="#" style="font-size: 12px;"></a>
                        </div>

                    </div>
                    <div class="big_banner_center_centbotton">
                        <div style="height: 28px;width: 100%;line-height: 28px;padding-left: 12px;box-sizing: border-box;color: #666;font-size: 12px;padding: 0 0 10px 10px;">
                            <span>促销信息:</span>
                            <span style="background-color: #e4393c;color: #fff;font-size: 12px;">立减</span>
                            <span style="color: #e4393c;">下单即享200元优惠</span>
                        </div>
                        <div style="font-size: 12px;padding-top: 10px;">
                            <span style="padding-left: 10px;">服&emsp;&emsp;务</span>
                            <span>由 乐视商城官方旗舰店 发货并提供售后服务</span>
                        </div>
                        <div style="font-size: 12px;padding-top: 10px;padding-left: 11px;">
                            <span>配 送 至：</span>
                            <button>请选择 ⅴ</button>
                            <span>付款成功后， 预计<i style="color: #d7000f">48小时</i>内发货</span>
                        </div>
                    </div>
                    <div class="big_banner_center_botton">
                        <div>
                            <div class="left">颜色：</div>
                            <div class="fangkuang">
                                <div class="cent">宝石蓝</div>

                            </div>
                        </div>

                    </div>
                    <div class="shuliang">
                        <span style="margin-left: 5px;position: relative;top: -15px;">购买数量:</span>
                        <div class="jiajian">
                            <input type="text" name="" id="" style="height: 100%;width: 35px;padding-left: 12px;box-sizing: border-box;" value="1">
                            <button class="jia">+</button>
                            <button class="jian">-</button>
                        </div>
                        <span class="kucun" style="position: relative;top: -15px;"></span>
                    </div>
                    <div class="goumai">
                        <button class="b1">立即购买</button>&nbsp;&nbsp;&nbsp;&nbsp;
                        <button class="b2"><a id="aa1" href="#">加入购物车</a></button>&nbsp;&nbsp;&nbsp;&nbsp;
                        <button class="b3">收藏</button>
                    </div>
                </div>
                <div class="big_banner_right_right" style="font-size: 12px;">
                    <div style="box-sizing: border-box; height: 50px;width: 175px;color: #005aa0;padding-left: 5px; padding-top: 18px;border-bottom: 1px dashed #999;">
                        乐视商城官方旗舰店</div>


                    <div style="width: 175px;height: 32px;padding-left: 5px;line-height: 32px;border-bottom: 1px dashed #999;">
                        商家满意度</div>
                    <div style="width: 175px;line-height: 20px;box-sizing: border-box;padding-top: 2px;padding-bottom: 3px; padding-left: 5px;border-bottom: 1px dashed #999;">
                        <p>商品描述：<i>4.8</i>分</p>
                        <p>服务态度：<i>4.8</i>分</p>
                        <p>发货速度：<i>4.8</i>分</p>
                    </div>
                    <div style="width: 175px;height: 70px;line-height: 35px;border-bottom: 1px dashed #999;padding-left: 5px;">
                        <p>店铺名称：乐视商城官方旗舰店</p>
                        <p>所在地</p>
                    </div>
                    <div style="width: 175px;height: 70px;border-bottom: 1px dashed #999;padding-left: 5px;line-height: 35px;">
                        <p>联系客服</p>
                        <p>在线客服</p>

                    </div>
                    <div style="padding-top: 10px;font-size: 12px;">
                        <button style="font-size: 12px;width: 72px;height: 27px;">进入店铺</button>
                        <button style="font-size: 12px;width: 72px;height: 27px;">收藏店铺</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="tuijian">
            <div class="tuijian_biaoti">精品推荐</div>
            <div>
                <ul>
                    <li>
                        <div>
                            <a href="#"><img style="margin: auto;" width="160" height="160" src="https://img2-lemall.letvimg.com/le-cloud/ad_mobile/resource/img/202112/1638841974571.jpg">
                            </a>
                        </div>
                        <p style="width: 100%;text-align: center;padding-top: 4px;">乐视智能手机 S1 宝石蓝</p>
                        <p style="width: 100%;text-align: center;padding-top: 4px;color: #d7000f;">￥1599</p>
                    </li>
                    <li>
                        <li>
                            <div>
                                <a href="#"><img style="margin: auto;" width="160" height="160" src="https://img1-lemall.letvimg.com/le-cloud/ad_mobile/resource/img/202112/1638841925254.jpg">
                                </a>
                            </div>
                            <p style="width: 100%;text-align: center;padding-top: 4px;">乐视智能手机 S1 宝石蓝</p>
                            <p style="width: 100%;text-align: center;padding-top: 4px;color: #d7000f;">￥1599</p>
                        </li>
                    </li>
                </ul>
            </div>
        </div>
        <div class="xiangqing">
            <div>
                <ul>
                    <li><a class="shangping" href="#">商品详情</a>
                    </li>
                    <li><a href="#">规格参数</a></li>
                    <li><a href="#">商品评价（3）</a></li>
                    <li><a href="#">咨询（0）</a></li>
                </ul>
            </div>
        </div>
        <div class="xiangqingtu">
            <div class="p-parameter">
                <ul id="parameter2">
                    <li>商品名称：乐视智能手机 S1 湖光绿</li>
                    <li>
                        店铺：
                        <a href="#" target="_blank">乐视商城官方旗舰店</a>
                    </li>
                    <li>
                        上架时间：2021-11-01 14:46:23
                    </li>
                    <li>
                        运行内存：8G
                    </li>
                    <li>
                        机身存储：256G
                    </li>
                    <li>
                        屏幕尺寸：6.45-6.54英寸
                    </li>
                    <li>
                        系统：Android
                    </li>
                    <li>
                        NFC功能：不支持
                    </li>
                    <li>
                        USB接口类型：Type-c
                    </li>
                    <li>
                        SIM卡类型：双卡或单卡+TF卡，Nano卡
                    </li>
                    <li>
                        5G网络：支持
                    </li>
                    <li>
                        屏幕材质：LED
                    </li>
                </ul>
                <div style="width: 990px;">
                    <p style="width: 970px; text-align: right;color: rgba(11, 105, 247, 0.726);" href="#">更多参数&gt;&gt;
                    </p>
                </div>
            </div>
        </div>
        <div class="imges">
            <div style="width: 100%;">
                <div style="width: 750px; margin: 0 auto;">
                    <p>
                        <a target="_self" href="https://bbs.le.com/thread-2685097-1.html">
                            <img src="https://img1-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202110/1635250630768.jpg">
                        </a>
                        <img src="https://img1-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656180047.jpg">
                    </p>
                    <p>
                        <img src="https://img0-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656182393.jpg">
                    </p>
                    <p>
                        <img src="https://img3-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656184894.jpg">
                    </p>
                    <p>
                        <img src="https://img1-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656187384.jpg">
                    </p>
                    <p>
                        <img src="https://img2-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656190290.jpg">
                    </p>
                    <p>
                        <img src="https://img0-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656192454.jpg">
                    </p>
                    <p>
                        <img src="https://img3-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656194810.jpg">
                    </p>
                    <p>
                        <img src="https://img1-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656196598.jpg">
                    </p>
                    <p>
                        <img src="https://img2-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632656198480.jpg">
                        <img src="https://img2-lemall.letvimg.com/le-cloud/s-pc-oa/resource/img/202109/1632726175880.jpg">
                    </p>
                    <p><br></p>
                </div>
            </div>
        </div>
    </div>
    <footer></footer>
</body>

</html>
<script src="goodsAndShoppingCart/js/cookieTools.js"></script>
<script src="http://libs.baidu.com/jquery/1.9.0/jquery.js"></script>
<script>
    $("header").load("1.header.html");
    $("footer").load("3.foot.html");
</script>
<script>
    $("header").delegate(".nav", "mouseover", function() {
        $(".navsort_cent_quanbu_select").css({
            display: "none"
        })
    })
</script>
<script src="js/详情页面.js"></script>
<script>
    console.log(location.search.split('=')[1]);
    $(function() {
        getData();
    })

    function getData() {
        $.get("goodsAndShoppingCart/getGoodsInfo.php", {
            goodsId: location.search.split('=')[1]
        }, function(data) {
            console.log(JSON.parse(data));
            let arr = JSON.parse(data);





            $(".small-box").css({
                backgroundImage: `url(${arr.beiyong3})`
            });
            $("#img1").attr("src", arr.beiyong3);
            $("#img2").attr("src", arr.beiyong4);
            $("#img3").attr("src", arr.beiyong5);
            $("#img4").attr("src", arr.beiyong6);
            $("#img5").attr("src", arr.beiyong7);
            $(".big_banner_center_top h1").html(arr.goodsName);

            $(".big_banner_center_top div").html(arr.goodsDesc);
            $("#jiage").html(arr.goodsPrice);
            $(".del").html(arr.beiyong2);
            $("#pingjia").html(arr.beiyong1);
            $(".kucun").html(`(库存${arr.goodsCount}件)`);


        })
    }
    // =================================添加购物车========================
    $("#aa1").click(function() {
        $.post("goodsAndShoppingCart/addShoppingCart.php", {
            "vipName": getCookie("usernum"),
            "goodsId": location.search.split('=')[1],
            "goodsCount": "1"
        }, function(data) {

            if (data.trim() == 1) {
                location.href = "shopping.html?goodsId=" + getCookie("usernum");

            } else {
                location.href = "3.登录页面.html";

            }
        })
    })
</script>